<template>
  <el-cascader
    :options="options"
    :props="props"
    v-model="selectedOptions"
    :size="size"
    @change="handleChange">
  </el-cascader>
</template>

<script>
import { regionDataPlus } from 'element-china-area-data';

export default {
  props: {
    size: {
      type: String,
      default: 'medium',
    },
  },
  data() {
    return {
      options: regionDataPlus,
      selectedOptions: [],
      props: {
        value: 'label',
      },
    };
  },
  components: {
  },
  created() {
    regionDataPlus[0].label = '线上';
    regionDataPlus[0].value = 'online';
  },
  methods: {
    handleChange(value) {
      this.$emit('locale', value);
    },
    clear() {
      this.electedOptions = [];
    },
  },
};
</script>

<style scoped lang="scss">

</style>
